package lxt.service;

import java.util.List;

import lxt.entity.UserInfo;


public interface UserService {
	/**
	 * 判断用户是否存在
	 * @param name
	 * @param pwd
	 * @return
	 */
	public UserInfo isExist(String name,String pwd)throws Exception;
	/**
	 * 加载用户信息 
	 * @return
	 */
	public List<UserInfo> loadUser(String username,int offset, int length) throws Exception;
	/**
	 * 添加用户
	 */
	public boolean addUser(UserInfo user)throws Exception;
	/**
	 * 根据name查找用户
	 */
	public UserInfo loadUserById(String username)throws Exception;
	/**
	 * 修改用户
	 */
	public boolean updateUser(UserInfo user)throws Exception;
	/**
	 * 删除用户
	 */
	public boolean deleteUser(String username,UserInfo user)throws Exception;
	/**
	 * 查询数量
	 */
	public int loadAllUserCount(String username)throws Exception;
	
}
